import request from '@/utils/request'

// 查询试题题库章节列表
export function listRepo(query) {
  return request({
    url: '/paper/repo/list',
    method: 'get',
    params: query
  })
}

// 查询试题题库章节详细
export function getRepo(repoId) {
  return request({
    url: '/paper/repo/' + repoId,
    method: 'get'
  })
}

// 新增试题题库章节
export function addRepo(data) {
  return request({
    url: '/paper/repo',
    method: 'post',
    data: data
  })
}

// 修改试题题库章节
export function updateRepo(data) {
  return request({
    url: '/paper/repo',
    method: 'put',
    data: data
  })
}

// 删除试题题库章节
export function delRepo(repoId) {
  return request({
    url: '/paper/repo/' + repoId,
    method: 'delete'
  })
}
